void main()
{
	if ( to_int( form_field( "whichboard" ) ) < 9 ) exit;

	buffer page = visit_url();
	matcher player = create_matcher( "(<a class=nounder href=\"showplayer.php\\?who=[\\d]+\">)<b>(.+?)</b>", page );
	int i = 0;
	while ( player.find() )	
	{
		i = ( i % 35 ) + 1;
		string place = ( i < 10 ? "&nbsp;&nbsp;" : "" ) + i;
		int start = page.index_of( player.group(0) );
		int end = start + player.group(0).length();
		#string color = i == 1 ? "#EEC900" : i <= 12 ? "#C0C0C0" : "#8C7853"; 
		string color = i == 1 ? "#DAA520" 
			: i <= 12 ? "#909090" 
			: "#B87333";
		replace( page, start, end, player.group(1) + place + " " + "<span style='font-weight:600;color:"+color+"'>" + player.group(2) + "</span>" );
	}
	
	page.write();
}